home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 86
/
(Vol 86) My Disc.iso
/
Games
/
restaurante_1072.swf
/
scripts
/
__Packages
/
Candle.as
< prev
next >
Wrap
Text File
|
2009-04-16
|
6KB
|
172 lines
if(true)
{
if(true)
{
§§push(false);
}
if(!§§pop())
{
if(true)
{
if(true)
{
§§push(false);
}
if(!§§pop())
{
if(!_global.Candle)
{
_global.Candle extends BoundItem;
var _loc2_ = _global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}.prototype;
_global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}.__get__MCLINK = function()
{
return "Candle";
};
_global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}.__get__FIREDELAY = function()
{
return 3000;
};
_loc2_.__set__mc = function(value)
{
this._mc.removeMovieClip();
this._mc = value;
return this.__get__mc();
};
_loc2_.init = function()
{
this.bornPoint = new flash.geom.Point(this.__get__mc()._x,this.__get__mc()._y);
var obj = this;
this.__get__mc().onPress = function()
{
obj.__get__mc().onMouseMove = function()
{
obj.onMouseMove();
updateAfterEvent();
};
obj.__get__mc().startDrag();
Mission.getMission().draggingMc = this;
Mission.getMission().refreshDepth();
};
this.__get__mc().onRelease = function()
{
obj.mcDropped();
};
};
_loc2_.onMouseMove = function()
{
if(this.__get__table() == null)
{
this._table = this.getTouchTable();
}
else if(McTools.isMouseInMc(this.__get__table().__get__mc()))
{
this.__get__table().onRollOver();
}
else
{
this.__get__table().onRollOut();
this._table = null;
}
};
_loc2_.mcDropped = function()
{
this._table = this.getTouchTable();
this.__get__mc().stopDrag();
this.__get__mc().onMouseMove = null;
Mission.getMission().draggingMc = null;
var obj = this;
if(this.__get__table() != null)
{
this.__get__mc().onPress = null;
this.__get__mc().onRelease = null;
this.__get__mc().removeMovieClip();
this.__set__mc(this.__get__table().__get__deskMc().attachMovie(Candle.__get__MCLINK(),"candleOnDesk" + getTimer(),this.__get__table().__get__deskMc().getNextHighestDepth(),{_x:-15,_y:-20}));
var interval = setInterval(function()
{
obj.active();
clearInterval(interval);
}
,Candle.__get__FIREDELAY());
}
else
{
this.__get__mc()._x = this.bornPoint.x;
this.__get__mc()._y = this.bornPoint.y;
}
};
_loc2_.getTouchTable = function()
{
var _loc2_ = Mission.getMission().__get__tables();
var _loc1_ = 0;
while(_loc1_ < _loc2_.length)
{
if(McTools.isMouseInMc(_loc2_[_loc1_].mc) && Table(_loc2_[_loc1_]).__get__numCustomers() >= Table(_loc2_[_loc1_]).__get__maxNumCustomers() && !Table(_loc2_[_loc1_]).__get__customerLeave())
{
return _loc2_[_loc1_];
}
_loc1_ = _loc1_ + 1;
}
return null;
};
_loc2_.active = function()
{
Mission.getMission().getBound(this);
this._num = this._num - 1;
if(this.__get__mc() && this.__get__num() <= 0)
{
this.terminate();
}
};
§§push((_global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}).addProperty("FIREDELAY",_global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}.__get__FIREDELAY,function()
{
}
));
§§push((_global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}).addProperty("MCLINK",_global.Candle = function($mc, $num, $heartsNum)
{
super($mc,$num,$heartsNum);
this.init();
}.__get__MCLINK,function()
{
}
));
§§push(_loc2_.addProperty("mc",function()
{
}
,_loc2_.__set__mc));
§§push(ASSetPropFlags(_global.Candle.prototype,null,1));
}
§§pop();
}
}
§§goto(addr427);
}
§§push(§§pop() + function §\x1b�\x02§(§�\x07§, §\x01§, §\x02\x01§, §\x01§, §��t\x02�n\x02=§, _global, Candle, init, BoundItem, prototype, __get__MCLINK, __get__FIREDELAY, __set__mc, _mc)
{
});
}
addr427: